package com.fishing.service.impl;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.fishing.mapper.LogTableOperMapper;
import com.fishing.service.LogTableOperService;
@Service
public class LogTableOperServiceImpl implements LogTableOperService {
	@Autowired
	private LogTableOperMapper logTableOperMapper;

	@Override
	public List<String> queryTableNamesByDaysList(Map<String, Object> map) throws Exception {
		return this.logTableOperMapper.queryTableNamesByDaysList(map);
	}

	@Override
	public List<String> queryLogTableNamesByDaysList(Map<String, Object> map) throws Exception {
		return this.logTableOperMapper.queryLogTableNamesByDaysList(map);
	}

	@Override
	public int selectExistField(String tableName, String fieldName) throws Exception {
		Map<String, Object> map = new HashMap<String, Object>();
		map.put("tableName", tableName);
		map.put("fieldName", fieldName);
		return this.logTableOperMapper.selectExistField(map);
	}

}
